#include "client.h"

int recvn(int sockfd, void *buf, int length){
    int total = 0; 
    char *p = (char *)buf;
    while(total < length){
        ssize_t sret = recv(sockfd,p+total,length-total,0);
        total += sret;
    }
    return 0;
}
